4D Chart v13CT SET HIGHLIGHT |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D Chart v13
CT SET HIGHLIGHT
|
CT SET HIGHLIGHT ( area ; scope ; first ; last ) | ||||||||
Parameter | Type | Description | ||||||
area | Longint |
![]() |
4D Chart area | |||||
scope | Longint |
![]() |
-1 = First object in a document 0 = First object in selection >0 = Object ID | |||||
first | Integer |
![]() |
Position of first character minus 1 | |||||
last | Integer |
![]() |
Position of last character | |||||
The CT SET HIGHLIGHT command highlights characters within the text object in area described by scope.
If the object described by scope is not a text object, CT SET HIGHLIGHT does nothing.
first and last determine which characters are highlighted. first is one less than the first character position to be highlighted. last is the last character position to be highlighted. If first equals last, no characters are selected and the insertion point is between first and first +1. If last is greater than the number of characters in the text object, CT SET HIGHLIGHT highlights characters to the end of the text object.
CT SET HIGHLIGHT does not highlight only part of a reference. If any portion of a reference is highlighted, CT SET HIGHLIGHT adjusts the highlight to include the entire reference.
This example gets the text of the selected text object and looks for the name “4th Dimension”. If “4th Dimension” is found, it is highlighted and then made bold.
$Find :=Position("4th Dimension";$Text)
If($Find #0)
CT SET HIGHLIGHT(Area;0;$Find -1;$Find +12)
CT SET TEXT ATTRIBUTES(Area;-3;-1;-1;1;-1;-1)
End if
Product: 4D Chart
Theme: CT Objects
Number:
14600
Created: 4D Chart 1